#include <iostream>
#include <queue>

int main()
{
    // std::priority_queue<int> q; // 默认最大堆
    std::priority_queue<int,std::vector<int>,std::greater<int>> q;   // 最小堆
    for(int i = 0;i < 10;i++)
    {
        q.push(i + 1);
    }
    while(!q.empty())
    {
        std::cout<<q.top()<<" ";
        q.pop();
    }
    std::cout<<std::endl;
    return 0;
}
